package com.omkarpatil.learningjpa2.mapping.onetoone.jointable.secondary;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;

@Entity(name = "OtoJoinSecondaryTableDesk")
@Table(name = "oto_join_sectable_desk")
public class Desk {
	private int id;
	private String number;
	
	public Desk() {}

	public Desk(String number) {
		this.number = number;
	}

	@Id
	@GeneratedValue
	@Column(name = "desk_id")
	public int getId() {
		return id;
	}

	private void setId(int id) {
		this.id = id;
	}

	@Column(nullable = false, length = 30)
	public String getNumber() {
		return number;
	}

	public void setNumber(String number) {
		this.number = number;
	}	
}
